Non-linear drift calibration

This is an example where there exists non-linear drift within an inert TAP experiment. This example is used to compare the traditional calibration vs TEAK. The goal of this demonstration is to show how to use TEAK. The data set consists of two pulses in gases (Argon and CO2) and measurements of the fragmentation patterns of CO2. The calibration is performed on the measured gas species (Argon and CO2).

Reading in the data and removing known outgassing.

For a base comparision, the zeroth moment of Argon and CO2 are plotted against each other without any baseline correction nor calibration. Both series voltage values are close to one another and should have minimal scaling difference. However, there exists significant drift within the experiment. Some of the M0 measurements are relatively close (near pulse 150) while others differ significantly (pulse 75).

Traditional calibration

All data is baseline corrected. The traditional method selects a time range to determine the baselien (4.7 to 5 seconds).

Below is code for determining the mean and standard deviation of each flux after baseline correction. This is not necessary in preprocessing the data, but is used to show evidence of the Gamma distribution as the residence time distribution. More specifically, if the mean and standard deviation show a linear trend, then this follows the same trend within the Gamma distribution.

The mean values calculated earlier can also be used to determine the calibration coefficient for each gas with respect to argon. This is the typically process to determine a calibration coefficient within an inert experiement. More specificially, the calibration coefficient is the mean argon zeroth moment is divided by each species mean zeroth moment.

Using the calibration coefficient, each CO2 flux is scaled to be the same mean argon zeroth moment.

Below shows a plot of the Argon vs CO2 moments after calibration. The difference between individual pulse indices match better than previously shown on the raw data.

TEAK Calibration

Again, before any calibration, the data is baseline corrected. Note that the TEAK method uses information about the residence time distribution to determine the baseline coefficient. TEAK does require more time in computation due to the smoothing applied.

The second step of TEAK is to calibrate the inert species (Argon) to itself such that it is consistent in all pulse numbers.

After self calibrating the Argon response, the Argon is set to the reference species of CO2. Finally, the CO2 values are calibrated agains the Argon.

A simple plot of the Argon and CO2 compared to one another. The Argon and CO2 almost perfectly align in this case.

Finally, the traditional and TEAK methods of calibration are compared to one another below. TEAK is able to deal with the drift in the measurements as well as provide a closer representation of the CO2 compared to Argon.

To compare the two processes quantitatively, the root mean square error (RMSE) is calculated from the difference of Argon to CO2 for each method. The ratio of the traditional and TEAK RMSE reveals that TEAK reduces the error by a factor of approximately 30 times.